String Diagrams

String diagrams are the superior diagrammatic calculus for 2-category theory.

The basic idea is to flip the dimensions of everything.

So for the setup of 2 -cells , 2 -cells , and a -cell , it would look like

Note the direction of the -cell, the domain is on the bottom.

Composition becomes dead simple, you stack diagrams in the obvious way that connects the same labelled things (regions/lines/nodes). For example, vertical composition looks like this. You can infer the signatures of the new cells and .

And here is how horizontal composition of -cells looks like:

There is this weird convention where identity -cells (for ) are just not drawn. Don't know why but it does reduce the effort I need to put into these diagrams so thats cool.

To have some sense of how string diagrams work, let's directly jump into the examples given at the start of the 2-category theory section.

  1. Adjunctions.

    The functors themselves are straightforward to visualize, so here is the picture of the natural transformations and :

    The real fun is describing the snake identities, because they just feel natural represented like this:

    String diagrams almost just convert topological intuition into formal category theory manipulation, which the example of snake identities shows very clearly.

  2. Kan Extensions.

    Again sticking with Right Kan Extensions, the definition has as setup the diagram

    and the universal property reads

    for some unique .

    Again its quite easy to see how such a diagram is topologically convinving and yet is actual category theory.

  3. Monads.

    There will still be no explanation of the classic meme here (yet). Last time I skipped the coherence conditions in the definition of a monad, but now you get to witness them in the form of string diagrams. Since the only functor involved here is an endofunctor, all labellings except the natural transformations are omitted.

    The associativity condition is represented by

    and the unitality condition is represented by

    While these are less of topological manipulations, they do very clearly show the interaction between the natural transformations and what the relevant coherence conditons encoded in commutative diagrams actually do.